package com.bw.lib_common.utils

import com.bw.lib_log.Logger
import com.bw.lib_log.LoggerLevel
import com.bw.lib_log.LoggerStrategy


/**
 * @Author : ZhouZiYao
 * @Time : On 2023/11/13 13:57
 * @Description : LoggerUtils
 */
class LoggerUtils {

    companion object{
        @JvmStatic
        private val logger by lazy {
            Logger.Builder()
                .setStrategy(LoggerStrategy.LOGCAT)
                .setDebug(true)
                .setTag("LoggerUtils")
                .setLevel(LoggerLevel.Error)
                .setSaveUrl("http://192.168.1.100:8080/api/log/save")
                .build()
        }

        @JvmStatic
        fun d(tag: String, log: String){
            logger.d(tag, log)
        }

        @JvmStatic
        fun v(tag: String, log: String){
            logger.v(tag, log)
        }

        @JvmStatic
        fun i(tag: String, log: String){
            logger.i(tag, log)
        }

        @JvmStatic
        fun w(tag: String, log: String){
            logger.w(tag, log)
        }

        @JvmStatic
        fun e(tag: String, log: String){
            logger.e(tag, log)
        }
    }

}